<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
  <head>
    <title>驳回申购单</title>
    <script type="text/javascript">
      Ext.onReady(function(){
        var id = <%= params[:id] %>;
        var rejectPurchaseForm=new Ext.form.FormPanel({
          width:600,
          buttonAlign:'center',
          autoHeight:true,
          fileUpload: true,
          bodyStyle: 'padding:5px',
          labelWidth:100,
          waitMsgTarget: true,
          frame: true,
          reader:new Ext.data.JsonReader({
          },[
            {name:'id'},
            {name:'reject_reason'}
          ]
        ),
          items:[{
              layout:'column',
              items:[{
                  columnWidth:1,
                  layout:'form',
                  labelAlign: 'top',
                  items:[{
                      xtype:'textarea',
                      fieldLabel: '驳回原因',
                      name: 'reject_reason',
                      allowBlank:false,
                      readOnly:true,
                      height:150,
                      anchor: '95%'
                    }]
                }]
            }],
          buttons:[{
              text:'确定',
              disabled:true,
              handler: function(){
                     
              }
            },{
              text:'取消',
              handler:function(){
                rejectPurchaseWin.destroy();
              }
            }]
        });
        rejectPurchaseForm.form.load({
          url: '/purchase/getRejectReasonOfPurchase?id=' + id,
          success: function(form, action){
          },
          failure: function(form, action){
            Ext.MessageBox.alert('提示信息', '信息加载失败');
          }
        });
        rejectPurchaseForm.render('reject_purchase_form');
      })
    </script>
  </head>
  <body>
    <div id="reject_purchase_form"></div>
  </body>
</html>
